import axios from "axios"

const API_URL = "http://localhost:8080/app/order-transactions";

// export const saveFlow = (myorder, formToken) => {
//     return axios.post(`${API_URL}`, myorder, {
//         headers: { "formToken": formToken }
//     })
// }

// 支付接口
export function saveFlow(order, token) {
  return axios.post(`${API_URL}`, order, {
    headers: {
      formToken: token // 携带幂等 token
    },
    responseType: 'text' // 防止 Axios 将 HTML 当作 JSON 解析
  })
}

export const searchAllVo = (transactionsId) => {
    return axios.get(`${API_URL}/searchAll/${transactionsId}`)
}




